abstract class Animal1 {
    Animal1() {
        System.out.println("Animal constructor");
    }

    abstract void sound();


}

class Dog1 extends Animal1 {
    Dog1() {
        super();  // 调用父类的构造方法
        System.out.println("Dog constructor");
    }

    @Override
    void sound() {
        System.out.println("Dog barks");
    }
}

class abstract_Main1{
    public static void main(String args[]){
        Animal1 dog = new Dog1();
        dog.sound();
    }

}